package com.ruoyi.buss.task.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.buss.task.mapper.DataTaskExRecordBackMapper;
import com.ruoyi.buss.task.domain.DataTaskExRecordBack;
import com.ruoyi.buss.task.service.IDataTaskExRecordBackService;

/**
 * 营销任务执行记录退回Service业务层处理
 * 
 * @author sxy
 * @date 2021-07-16
 */
@Service
public class DataTaskExRecordBackServiceImpl implements IDataTaskExRecordBackService 
{
    @Autowired
    private DataTaskExRecordBackMapper dataTaskExRecordBackMapper;

    /**
     * 查询营销任务执行记录退回
     * 
     * @param taskExRecordId 营销任务执行记录退回ID
     * @return 营销任务执行记录退回
     */
    @Override
    public DataTaskExRecordBack selectDataTaskExRecordBackById(String taskExRecordId)
    {
        return dataTaskExRecordBackMapper.selectDataTaskExRecordBackById(taskExRecordId);
    }

    /**
     * 查询营销任务执行记录退回列表
     * 
     * @param dataTaskExRecordBack 营销任务执行记录退回
     * @return 营销任务执行记录退回
     */
    @Override
    public List<DataTaskExRecordBack> selectDataTaskExRecordBackList(DataTaskExRecordBack dataTaskExRecordBack)
    {
        return dataTaskExRecordBackMapper.selectDataTaskExRecordBackList(dataTaskExRecordBack);
    }

    /**
     * 新增营销任务执行记录退回
     * 
     * @param dataTaskExRecordBack 营销任务执行记录退回
     * @return 结果
     */
    @Override
    public int insertDataTaskExRecordBack(DataTaskExRecordBack dataTaskExRecordBack)
    {
        dataTaskExRecordBack.setCreateTime(DateUtils.getNowDate());
        return dataTaskExRecordBackMapper.insertDataTaskExRecordBack(dataTaskExRecordBack);
    }

    /**
     * 修改营销任务执行记录退回
     * 
     * @param dataTaskExRecordBack 营销任务执行记录退回
     * @return 结果
     */
    @Override
    public int updateDataTaskExRecordBack(DataTaskExRecordBack dataTaskExRecordBack)
    {
        dataTaskExRecordBack.setUpdateTime(DateUtils.getNowDate());
        return dataTaskExRecordBackMapper.updateDataTaskExRecordBack(dataTaskExRecordBack);
    }

    /**
     * 批量删除营销任务执行记录退回
     * 
     * @param taskExRecordIds 需要删除的营销任务执行记录退回ID
     * @return 结果
     */
    @Override
    public int deleteDataTaskExRecordBackByIds(String[] taskExRecordIds)
    {
        return dataTaskExRecordBackMapper.deleteDataTaskExRecordBackByIds(taskExRecordIds);
    }

    /**
     * 删除营销任务执行记录退回信息
     * 
     * @param taskExRecordId 营销任务执行记录退回ID
     * @return 结果
     */
    @Override
    public int deleteDataTaskExRecordBackById(String taskExRecordId)
    {
        return dataTaskExRecordBackMapper.deleteDataTaskExRecordBackById(taskExRecordId);
    }
}
